<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>gdata.objson.jsonbuilder.JSON</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css"></link>
</head>
<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">

<!-- =========== START OF NAVBAR =========== -->
<table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="center">
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="trees.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="indices.html">Index</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar" align="right" width="100%">
      <table border="0" cellpadding="0" cellspacing="0">
      <tr><th class="navbar" align="center">
        <p class="nomargin">
          objson
      </p></th></tr></table>
    </th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <font size="-1"><b class="breadcrumbs">
        Package&nbsp;gdata ::
        Package&nbsp;objson ::
        <a href="gdata.objson.jsonbuilder-module.html">Module&nbsp;jsonbuilder</a> ::
        Class&nbsp;JSON
      </b></font></br>
    </td>
    <td><table cellpadding="0" cellspacing="0">
      <tr><td align="right"><font size="-2">[show&nbsp;private&nbsp;|&nbsp;<a href="../public/gdata.objson.jsonbuilder.JSON-class.html">hide&nbsp;private</a>]</font></td></tr>
      <tr><td align="right"><font size="-2">[<a href="frames.html"target="_top">frames</a>&nbsp;|&nbsp;<a href="gdata.objson.jsonbuilder.JSON-class.html" target="_top">no&nbsp;frames</a>]</font></td></tr>
    </table></td>
</tr></table>

<!-- =========== START OF CLASS DESCRIPTION =========== -->
<h2 class="class">Type JSON</h2>

<pre class="base-tree">
<a href="__builtin__.object-class.html"><code>object</code></a> --+
         |
        <b>JSON</b>
</pre><br />

<hr/>


<!-- =========== START OF METHOD SUMMARY =========== -->
<table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="summary">
  <th colspan="2">Method Summary</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><a name="__init__"></a><span class="summary-sig"><span class="summary-sig-name">__init__</span>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>version</span>,
          <span class=summary-sig-arg>encoding</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="gdata.objson.jsonbuilder.JSON-class.html#__repr__" class="summary-sig-name"><code>__repr__</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Override repr method to provide a package consistent object 
representation.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="gdata.objson.jsonbuilder.JSON-class.html#__str__" class="summary-sig-name"><code>__str__</code></a>(<span class=summary-sig-arg>self</span>)</span></code>
<br />
Return the string structure of the JSON data structure.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="gdata.objson.jsonbuilder.JSON-class.html#AddSubNode" class="summary-sig-name"><code>AddSubNode</code></a>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>sub_node</span>,
          <span class=summary-sig-arg>node</span>)</span></code>
<br />
Wrapper to the OBJson object CreateChild method.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="gdata.objson.jsonbuilder.JSON-class.html#build" class="summary-sig-name"><code>build</code></a>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>name</span>,
          <span class=summary-sig-arg>attrs</span>)</span></code>
<br />
Factory method to build the python dictionary object representing
the JSON structure.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="gdata.objson.jsonbuilder.JSON-class.html#DelSubNode" class="summary-sig-name"><code>DelSubNode</code></a>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>sub_node</span>,
          <span class=summary-sig-arg>node</span>)</span></code>
<br />
Wrapper to the OBJson object DelChild method.</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><a name="_delroot"></a><span class="summary-sig"><span class="summary-sig-name">_delroot</span>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><a name="_getroot"></a><span class="summary-sig"><span class="summary-sig-name">_getroot</span>(<span class=summary-sig-arg>self</span>)</span></code>
</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><a name="_setroot"></a><span class="summary-sig"><span class="summary-sig-name">_setroot</span>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>obj</span>)</span></code>
</td></tr>
<tr bgcolor="#e8f0f8" class="group">
  <th colspan="2">&nbsp;&nbsp;&nbsp;&nbsp;Inherited from object</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__delattr__" class="summary-sig-name"><code>__delattr__</code></a>(<span class="summary-sig-vararg">...</span>)</span></code>
<br />
x.__delattr__('name') &lt;==&gt; del x.name</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__getattribute__" class="summary-sig-name"><code>__getattribute__</code></a>(<span class="summary-sig-vararg">...</span>)</span></code>
<br />
x.__getattribute__('name') &lt;==&gt; x.name</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__hash__" class="summary-sig-name"><code>__hash__</code></a>(<span class=summary-sig-arg>x</span>)</span></code>
<br />
x.__hash__() &lt;==&gt; hash(x)</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__new__" class="summary-sig-name"><code>__new__</code></a>(<span class=summary-sig-arg>T</span>,
          <span class=summary-sig-arg>S</span>,
          <span class="summary-sig-vararg">...</span>)</span></code>
<br />
T.__new__(S, ...) -&gt; a new object with type S, a subtype of T</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__reduce__" class="summary-sig-name"><code>__reduce__</code></a>(<span class="summary-sig-vararg">...</span>)</span></code>
<br />
helper for pickle</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__reduce_ex__" class="summary-sig-name"><code>__reduce_ex__</code></a>(<span class="summary-sig-vararg">...</span>)</span></code>
<br />
helper for pickle</td></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><code><span class="summary-sig"><a href="__builtin__.object-class.html#__setattr__" class="summary-sig-name"><code>__setattr__</code></a>(<span class="summary-sig-vararg">...</span>)</span></code>
<br />
x.__setattr__('name', value) &lt;==&gt; x.name = value</td></tr>
</table><br />


<!-- =========== START OF PROPERTY SUMMARY =========== -->
<table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="summary">
  <th colspan="2">Property Summary</th></tr>
<tr><td align="right" valign="top" width="15%"><font size="-1">&nbsp;</font></td>
  <td><b><a href="gdata.objson.jsonbuilder.JSON-class.html#root"><code>root</code></a></b>: get/set/del OBJsontop root node</td></tr></table><br />


<!-- =========== START OF METHOD DETAILS =========== -->
<table class="details" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="details">
  <th colspan="2">Method Details</th></tr>
</table>

<a name="__repr__"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
  <h3><span class="sig"><span class="sig-name">__repr__</span>(<span class=sig-arg>self</span>)</span>
    <br /><i>(Representation operator)</i>
  </h3>
  Override repr method to provide a package consistent object 
  representation.
  <dl><dt></dt><dd>
    <dl><dt><b>Overrides:</b></dt>
      <dd><a href="__builtin__.object-class.html#__repr__"><code>__builtin__.object.__repr__</code></a></dd>
    </dl>
  </dd></dl>
</td></tr></table>

<a name="__str__"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
  <h3><span class="sig"><span class="sig-name">__str__</span>(<span class=sig-arg>self</span>)</span>
    <br /><i>(Informal representation operator)</i>
  </h3>
  Return the string structure of the JSON data structure.
  <dl><dt></dt><dd>
    <dl><dt><b>Overrides:</b></dt>
      <dd><a href="__builtin__.object-class.html#__str__"><code>__builtin__.object.__str__</code></a></dd>
    </dl>
  </dd></dl>
</td></tr></table>

<a name="AddSubNode"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
  <h3><span class="sig"><span class="sig-name">AddSubNode</span>(<span class=sig-arg>self</span>,
          <span class=sig-arg>sub_node</span>,
          <span class=sig-arg>node</span>=<span class=sig-default>None</span>)</span>
  </h3>
<pre class="literalblock">
Wrapper to the OBJson object CreateChild method.

Args:
  node: (optional) the object of which needs to add
        the sub_node to.
        default set to the root node.
  sub_node: the sub_node object.
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>

<a name="build"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
  <h3><span class="sig"><span class="sig-name">build</span>(<span class=sig-arg>self</span>,
          <span class=sig-arg>name</span>,
          <span class=sig-arg>attrs</span>=<span class=sig-default>None</span>)</span>
  </h3>
<pre class="literalblock">
Factory method to build the python dictionary object representing
the JSON structure.

Args:
  name: the JSON element name.
  attrs: (optional) whether the element has any attributes. In
         the form of ({attr:val})

Returns:
  Either a JSON root node or a JSON element object.

Raises:
  ObjectAlreadyBuiltError, when the object has already built.
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>

<a name="DelSubNode"></a>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>
  <h3><span class="sig"><span class="sig-name">DelSubNode</span>(<span class=sig-arg>self</span>,
          <span class=sig-arg>sub_node</span>,
          <span class=sig-arg>node</span>=<span class=sig-default>None</span>)</span>
  </h3>
<pre class="literalblock">
Wrapper to the OBJson object DelChild method.

Args:
  node: (optional) the parent node where the sub node belongs to.
        default set to the root node.
  sub_node: the sub_node that will be removed.
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>
<br />


<!-- =========== START OF PROPERTY DETAILS =========== -->
<table class="details" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="details">
  <th colspan="2">Property Details</th></tr>
</table>
<table width="100%" class="func-details" bgcolor="#e0e0e0"><tr><td>

<a name="root"></a>
<h3>root</h3>
get/set/del OBJsontop root node
<dl>
  <dt></dt>
  <dd>
    <dl>
      <dt><b>Get Method:</b></dt>
      <dd><span class="summary-sig"><a href="../private/gdata.objson.jsonbuilder.JSON-class.html#_getroot" class="summary-sig-name"><code>_getroot</code></a>(<span class=summary-sig-arg>self</span>)</span>
      </dd>
      <dt><b>Set Method:</b></dt>
      <dd><span class="summary-sig"><a href="../private/gdata.objson.jsonbuilder.JSON-class.html#_setroot" class="summary-sig-name"><code>_setroot</code></a>(<span class=summary-sig-arg>self</span>,
          <span class=summary-sig-arg>obj</span>)</span>
      </dd>
      <dt><b>Delete Method:</b></dt>
      <dd><span class="summary-sig"><a href="../private/gdata.objson.jsonbuilder.JSON-class.html#_delroot" class="summary-sig-name"><code>_delroot</code></a>(<span class=summary-sig-arg>self</span>)</span>
      </dd>
    </dl>
  </dd>
</dl></td></tr></table><br />


<!-- =========== START OF NAVBAR =========== -->
<table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="center">
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="trees.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="indices.html">Index</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar">&nbsp;&nbsp;&nbsp;<a class="navbar" href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
    <th class="navbar" align="right" width="100%">
      <table border="0" cellpadding="0" cellspacing="0">
      <tr><th class="navbar" align="center">
        <p class="nomargin">
          objson
      </p></th></tr></table>
    </th>
  </tr>
</table>

<table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
    <td align="left"><font size="-2">Generated by Epydoc 2.1 on Mon Jul 16 16:43:14 2007</font></td>
    <td align="right"><a href="http://epydoc.sourceforge.net"
                      ><font size="-2">http://epydoc.sf.net</font></a></td>
  </tr>
</table>
</body>
</html>
